/ Assembly List / LJCNetCommon / LJCAssemblyReflect / GetTypeSyntax

Namespace - LJCNetCommon


Parameters
typeReference - The Type object.

Returns

The Type syntax.

Syntax

C#
public String GetTypeSyntax(Type typeReference = null)

Creates and returns the Type syntax. (E)

Example

C#
using System;
using System.Reflection;
using LJC.Net.Common;
        
public string RetrieveTypeSyntax(string assemblyFileSpec, string fullTypeName)
{
  string retValue = null;
    
  // These calls are not required if an LJCAssemblyReflect reference is
  // used and the the following set methods have already been executed.
  LJCAssemblyReflect assemblyReflect = new LJCAssemblyReflect();
  assemblyReflect.SetAssembly(assemblyFileSpec);
  assemblyReflect.SetTypeReference(fullTypeName);
    
  retValue = assemblyReflect.GetTypeSyntax();
  return retValue;
}

Copyright © Lester J. Clark and Contributors.
Licensed under the MIT License.